#include <iostream>
using std::cout;
using std::endl;

class Base{
private:
    int _num;
    friend Base operator+(const Base &lhs, const Base &rhs);
    friend Base operator-(const Base &lhs, const Base &rhs);
    friend bool operator==(const Base &lhs, const Base &rhs);
public:
    Base(int num)
    :_num(num)
    {}
};

Base operator+(const Base &lhs, const Base &rhs){
    return Base(lhs._num + rhs._num);
}

Base operator-(const Base &lhs, const Base &rhs){
    return Base(lhs._num - rhs._num);
}

bool operator==(const Base &lhs, const Base &rhs){
    return lhs._num != rhs._num;
}

int main(){
    int i = 2;
    int j = 7;

    Base x(i);
    Base y(j);
    cout << (x + y == j - i) << endl;    

    return 0;
}

